home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2007 September / PCWSEP07.iso / Software / Linux / Linux Mint 3.0 Light / LinuxMint-3.0-Light.iso / casper / filesystem.squashfs / sbin / usplash_down < prev    next >
Encoding:
Text File  |  2007-04-02  |  883 b   |  44 lines

  1. #!/bin/sh
  2.  
  3. SPLASH=false
  4. VERBOSE=true
  5.  
  6. for x in $(cat /proc/cmdline); do
  7.         case $x in
  8.         splash*)
  9.                 SPLASH=true;
  10.                 ;;
  11.         quiet*)
  12.                 VERBOSE=false
  13.                 ;;
  14.         esac
  15. done
  16.  
  17. [ "$SPLASH" != "true" ] && exit 1
  18.  
  19. [ -f /etc/usplash.conf ] && . /etc/usplash.conf
  20.  
  21. # Clean up the console before we switch to it, to avoid text flicker:
  22. if [ -x /usr/bin/tput ]; then
  23.     tput -Tlinux reset > /dev/tty8
  24. fi
  25.  
  26. # Run usplash, switching to vt8
  27. if [ $VERBOSE = "true" ]; then
  28.     varg=-v
  29. else
  30.     varg=
  31. fi
  32. if [ "$xres" ] && [ "$xres" != 0 ] && [ "$yres" ] && [ "$yres" != 0 ]; then
  33.     /sbin/usplash -c -x "$xres" -y "$yres" $varg &
  34. else
  35.     /sbin/usplash -c $varg &
  36. fi
  37.  
  38. # Sleep hack to wait for us to be ready, only needed until usplash/bogl
  39. # can be properly daemonised:
  40. sleep 1
  41.  
  42. # Just because, tidyness is next to... Something or other:
  43. exit 0
  44.